package com.ruoyi.system.service.car4s_service.car4s_impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.car4s_mapper.Car4sPartsInfoMapper;
import com.ruoyi.system.domain.car4s_domain.Car4sPartsInfo;
import com.ruoyi.system.service.car4s_service.ICar4sPartsInfoService;

/**
 * 配件信息Service业务层处理
 * 
 * @author LK
 * @date 2024-06-29
 */
@Service
public class Car4sPartsInfoServiceImpl implements ICar4sPartsInfoService 
{
    @Autowired
    private Car4sPartsInfoMapper car4sPartsInfoMapper;

    /**
     * 查询配件信息
     * 
     * @param partsId 配件信息主键
     * @return 配件信息
     */
    @Override
    public Car4sPartsInfo selectCar4sPartsInfoByPartsId(Long partsId)
    {
        return car4sPartsInfoMapper.selectCar4sPartsInfoByPartsId(partsId);
    }

    /**
     * 查询配件信息列表
     * 
     * @param car4sPartsInfo 配件信息
     * @return 配件信息
     */
    @Override
    public List<Car4sPartsInfo> selectCar4sPartsInfoList(Car4sPartsInfo car4sPartsInfo)
    {
        return car4sPartsInfoMapper.selectCar4sPartsInfoList(car4sPartsInfo);
    }

    /**
     * 新增配件信息
     * 
     * @param car4sPartsInfo 配件信息
     * @return 结果
     */
    @Override
    public int insertCar4sPartsInfo(Car4sPartsInfo car4sPartsInfo)
    {
        return car4sPartsInfoMapper.insertCar4sPartsInfo(car4sPartsInfo);
    }

    /**
     * 修改配件信息
     * 
     * @param car4sPartsInfo 配件信息
     * @return 结果
     */
    @Override
    public int updateCar4sPartsInfo(Car4sPartsInfo car4sPartsInfo)
    {
        return car4sPartsInfoMapper.updateCar4sPartsInfo(car4sPartsInfo);
    }

    /**
     * 批量删除配件信息
     * 
     * @param partsIds 需要删除的配件信息主键
     * @return 结果
     */
    @Override
    public int deleteCar4sPartsInfoByPartsIds(Long[] partsIds)
    {
        return car4sPartsInfoMapper.deleteCar4sPartsInfoByPartsIds(partsIds);
    }

    /**
     * 删除配件信息信息
     * 
     * @param partsId 配件信息主键
     * @return 结果
     */
    @Override
    public int deleteCar4sPartsInfoByPartsId(Long partsId)
    {
        return car4sPartsInfoMapper.deleteCar4sPartsInfoByPartsId(partsId);
    }
}
